Implementing K-Nearest Neighbors Algorithm From Scratch